//
//  NSMutableAttributedString+Category.h
//  LNUniversal
//
//  Created by liu nian on 15/6/1.
//  Copyright (c) 2015年 Liu Nian site:http://iliunian.com. All rights reserved.
//

#import <Foundation/Foundation.h>
#import <UIKit/UIKit.h>

@interface NSMutableAttributedString (Category)
- (NSMutableAttributedString *)attributedWithFont:(UIFont *)font
                                        textColor:(UIColor *)color
                                            range:(NSRange)range;

+ (NSMutableAttributedString *)attributedString:(NSString *)string
                                           font:(UIFont *)font
                                      textColor:(UIColor *)color
                                          range:(NSRange)range;
/**
 *  获取一段富文本的rect
 *
 *  @param font 字体
 *  @param size 最大的容器size
 *
 *  @return 所占用的实际rect
 */
- (CGRect)rectWithFont:(UIFont *)font inSize:(CGSize)size;
@end
